#ifndef VARIABLEENTRY_H_
#define VARIABLEENTRY_H_

#include "TableEntry.h"

class VariableEntry : public TableEntry
{
public:
	VariableEntry();
	VariableEntry(Type type, Attribute attrib, int arraySize=0, bool param=false);
	VariableEntry(Type type, VariableAttribute va);
	virtual ~VariableEntry();
	
	int setAddress(int addr);
	void setParamFlag(bool isParam = true);
	
	void setAttribute(const VariableAttribute &va);
	void setAttribute(Attribute attrib, int arraySize=0);
	Attribute getAttribute();
	attr getAttr() const;
	int getArraySize() const;
	
	bool isParam() const;
	
	void setType(Type t);
	Type getType() const;
	
	std::ostream& inserter(std::ostream &os) const;
	
private:
	Type variableType;
	Attribute variableAttribute;
	int arraySize;
	bool isFunctionParameter;
};

#endif /*VARIABLEENTRY_H_*/
